// 1. 享元模式定义
function Person(name, age) { 
    this.name = name;
    this.age = age;
 }
 // 原型方法是共有的
 Person.prototype.getName = function () { 
     return this.name;
  }
  Person.prototype.getAge = function () { 
    return this.age;
 }
 let p1 = new Person();
 let p2 = new Person();